<?php
	$dir = '/images/index_flash';
	$welcome_img = $dir.'/welcome.jpg';
	$dp = opendir(sfConfig::get('sf_web_dir').$dir);
	$imgs = array();	
	while (($curFile = readdir($dp)) !== false ) {		
		if ($curFile != '.'	&&	$curFile != '..' && $curFile != '') {			
			if (is_dir(sfConfig::get('sf_web_dir').$dir.'/'.$curFile)) { 				
			} else {
				$tmp_strs = explode('.', $curFile);				
				if ($tmp_strs[0] != 'welcome') {
					$imgs[] = array(	
						'id' => $tmp_strs[0],							
						'name' => $dir."/".$curFile					
					);
				}
			}
		}
	}
	//var_dump($imgs);
?>
<div id="jzFlashPlay">
	<ul class="imgs">
	<?php foreach ($imgs as $i) { ?>
		<li><a href="#"><img src="<?php echo $i['name']; ?>" /></a></li>		
	<?php } ?>
	</ul>
	<img class="welcome" src="<?php echo $welcome_img; ?>">
</div>
<!-- 
<ul id="homepagebanner">

		<li>
		  <a href="/site/powerslave,id,32,nodeid,32,pcategory,55,_language,EN.html" style="background: url(/mediendatenbank2/show.php3?id=4730&nodeid=141&_language=EN) no-repeat 32px top;">
		    <img src="/imgdir/3dbb8942ecd114860eaf5b9cfe304688-homepagebanner.gif" />
		  </a>
		</li>
		
		<li>
		  <a href="/site/powerslave,id,32,nodeid,32,pcategory,32,_language,EN.html" style="background: url(/mediendatenbank2/show.php3?id=4726&nodeid=141&_language=EN) no-repeat 32px top;">
		    <img src="/imgdir/62b010c0757bc533c63d4839e6640279-homepagebanner.gif" />
		  </a>
		</li>
		
		<li>
		  <a href="/site/powerslave,id,32,nodeid,32,pcategory,25,_language,EN.html" style="background: url(/mediendatenbank2/show.php3?id=4734&nodeid=141&_language=EN) no-repeat 32px top;">
		    <img src="/imgdir/795d311f1adabaf9d91a06212fd7df8c-homepagebanner.gif" />
		  </a>
		</li>
		
		<li>
		  <a href="/site/powerslave,id,32,nodeid,32,pcategory,16,_language,EN.html" style="background: url(/mediendatenbank2/show.php3?id=4724&nodeid=141&_language=EN) no-repeat 32px top;">
		    <img src="/imgdir/19787014ad88c01680aecfba29f27d73-homepagebanner.gif" />
		  </a>
		</li>
		
		<li>
		  <a href="/site/powerslave,id,32,nodeid,32,pcategory,6,_language,EN.html" style="background: url(/mediendatenbank2/show.php3?id=4732&nodeid=141&_language=EN) no-repeat 32px top;">
		    <img src="/imgdir/214f17cec132c9ee079535bc5d5a8f51-homepagebanner.gif" />
		  </a>
		</li>
		
		<li>
		  <a href="/site/powerslave,id,32,nodeid,32,pcategory,3,_language,EN.html" style="background: url(/mediendatenbank2/show.php3?id=4728&nodeid=141&_language=EN) no-repeat 32px top;">
		    <img src="/imgdir/fdc8b8c5e2dd9728975eb399e452cfbc-homepagebanner.gif" />
		  </a>
		</li>
		</ul>
<img id='hompagebanner_init' src='/mediendatenbank2/show.php3?id=4737&nodeid=141&_language=EN' />
 -->
<script type="text/javascript" >

	$(document).ready(function(){

	    lastBlock = $("#initialTab"); // erster offener Block (optional)
	    maxWidth = 584; // Breite eines geÃ¶ffneten Tabs
	    minWidth = 32;  // Breite eines geschlossenen Tabs

	    // Hover Ã¼ber eine Produktkategorie
	    $("#homepagebanner li a").hover(
	      function(){
		$(lastBlock).animate({width: minWidth+"px"}, { queue:false, duration:400 });
		$(this).animate({width: maxWidth+"px"}, { queue:false, duration:400});
		lastBlock = this;
	      }
	    );

	    // Reset auf Ausgangszustand
	    $("#homepagebanner").mouseleave(
	      function(){
		$(lastBlock).animate({width: minWidth+"px"}, { queue:false, duration:400 });
	      }
	    );
	});

</script>